#ifndef _NEPTUNER_SUBVIEW_H_
#define _NEPTUNER_SUBVIEW_H_

#include<string>
#include<iostream>
#include<vector>

#include"Funcalyzer.h"

class Subview
{
public:
	Funcalyzer*		m_pxFuncalyzer;
	std::ostream*	m_pxOut;
	std::string		m_sFilename;
	std::string		m_sOutputFile;
	int				m_nLevel;
	int				m_nLines;

	void printHeading(bool bClear=true);
	void printElement(bool bClear=true);
	void printFooting(bool bClear=true);
	void printBodyStart();
	void printBodyEnd();

	void linkify();
	std::string linkToUBoat(int nLine);

	void generatePaneSubmarine();
	void generatePaneSidebar();
	void generatePaneReport();

	std::vector<std::string> m_asOutputRow;
	int m_nSerialNumber;

	Subview();
	~Subview();

	void generateHeader();
	void generateBody();
	void generateFooter();

	void outputReturns();
    void outputCalls();
	void outputDataUsage();
	void outputComplexity();

	void setOutputFile(std::string sOutFile);
};

#endif
